package cn.com.hd.mall.web.webservices.entity;

import java.io.Serializable;

import cn.com.hd.mall.web.webservices.constant.WebservicesConstant;

public class BaseEntity implements Serializable {

	/** serialVersionUID */
	private static final long serialVersionUID = 1820354282576704753L;
	/** session user id */
	private String sessionId;
	/** 会话验证标识 */
	private String token;
	/** 页码 */
	public int page = WebservicesConstant.PAGE_CURRENT;
	/** 每页行数 */
	public int rows = WebservicesConstant.PAGE_SIZE;

	public String getSessionId() {
		return this.sessionId;
	}

	public void setSessionId(String sessionId) {
		this.sessionId = sessionId;
	}

	public String getToken() {
		return this.token;
	}

	public void setToken(String token) {
		this.token = token;
	}

	public int getPage() {
		if (this.page < 1) {
			return WebservicesConstant.PAGE_CURRENT;
		} else {
			return this.page;
		}
	}

	public void setPage(int page) {
		this.page = page;
	}

	public int getRows() {
		if (this.rows < 1) {
			return WebservicesConstant.PAGE_SIZE;
		} else {
			return this.rows;
		}
	}

	public void setRows(int rows) {
		this.rows = rows;
	}

}
